package com.ssc.controller.vo;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import org.hibernate.validator.constraints.Email;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.Size;

/**
 * 用户信息
 *
 * @author wuxianji
 * @since 2017/10/31 16:07
 **/
public class UserVO {
    /**
     * 用户ID
     */
    private Integer id;

    /**
     * 用户名
     */
    @NotBlank
    @Size(max = 50)
    private String userName;

    /**
     * 登录密码
     */
    @NotBlank
    @Size(max = 50)
    private String password;

    /**
     * 真实姓名
     */
    @NotBlank
    @Size(max = 50)
    private String realName;

    /**
     * 支付密码
     */
    @NotBlank
    @Size(max = 50)
    private String payPassword;

    /**
     * 邮箱
     */
    @Email
    private String email;

    /**
     * 推荐人
     */
    private Integer referrer;

    @Override
    public String toString() {
        return ToStringBuilder.reflectionToString(this, ToStringStyle.JSON_STYLE);
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getRealName() {
        return realName;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    public String getPayPassword() {
        return payPassword;
    }

    public void setPayPassword(String payPassword) {
        this.payPassword = payPassword;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public Integer getReferrer() {
        return referrer;
    }

    public void setReferrer(Integer referrer) {
        this.referrer = referrer;
    }
}
